home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
MacWorld 1999 January - Disc 2
/
Macworld (1999-01) (Disk 2).dmg
/
Serious Demos
/
Symbolic Composer 4.2
/
Environment
/
System
/
MRAC
/
Generate
/
g-tempo
< prev
Wrap
Lisp/Scheme
|
1998-10-24
|
1KB
|
57 lines
g-tempo seed range beat tempo length
(setq tempo1
(g-tempo .23 '(4 11) '1/4 (permute '(32 44 72 88)) 120))
(first tempo1)
=> (3/2 1/1 3/2 7/4 2/1 9/4 2/1 5/4 3/2 2/1 3/2 11/4 9/4 2/1 5/2 9/4)
(second tempo1)
=> (32 44 72 88 32 44 88 72 32 72 44 88 32 72 88 44)
(setq tempo2
(g-tempo .23 '((4 7) (3 6)) '1/4
'((32 44 72 88) (72 112)) '(60 60)))
(first tempo2)
=> (5/4 7/4 1/1 3/2 5/4 5/4 5/4 1/1 3/2 5/4 3/2 1/2
3/4 5/4 3/2 1/1 5/4 5/4 3/4 3/2 3/2 5/4 3/2 3/2)
(second tempo2)
=> (32 44 72 88 32 44 72 88 32 44 72 88 72
112 72 112 72 112 72 112 72 112 72 112)
SCORE:
(setq sym (g-cluster nil 's -12 12 '(4 5 7 9 3) '(6 5 7 8 4)))
(setq len (g-tuplet nil 1 4 'd 'n '(4 4 4 4 4 4 4) '(5 3 4 5)))
(setq tempo (g-tempo .23 '(3 5) '1/8 (permute '(32 44 72 88)) len))
(setq tempo-zone (first tempo))
(setq tempo-score (second tempo))
(def-symbol
inst (flatten sym))
(def-length
inst (flatten len))
(def-velocity
inst '60)
(def-zone
tempo tempo-zone
inst (zone-tick (length-of inst)))
(def-channel
inst k2000i-1)
(def-program k2000p
default '(stereo-grand))
(def-tonality
default (activate-tonality (chromatic c 5)))
(def-tempo tempo-score)
(compile-instrument-p "ccl;output:" "test0" inst)